<?php

namespace common\entities\common;

use Yii;

/**
 * This is the model class for table "myscrm_maintainer_account".
 *
 * @property string $user_id
 * @property string $user_code
 * @property string $username
 * @property integer $status
 * @property string $created_on
 * @property string $created_by
 * @property string $modified_on
 * @property string $modified_by
 */
class MyscrmMaintainerAccountEntity extends \common\entities\ConfigEntity
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'myscrm_maintainer_account';
    }


    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['user_id', 'user_code', 'username'], 'required'],
            [['status'], 'integer'],
            [['created_on', 'modified_on'], 'safe'],
            [['user_id'], 'string', 'max' => 36],
            [['user_code', 'username'], 'string', 'max' => 45],
            [['created_by', 'modified_by'], 'string', 'max' => 50]
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'user_id' => 'ID',
            'user_code' => '用户名',
            'username' => '姓名',
            'status' => '状态,1启用，0禁用',
            'created_on' => '创建时间',
            'created_by' => '创建人',
            'modified_on' => '修改时间',
            'modified_by' => '修改人',
        ];
    }
}
